package com.sezi.vo.page;

import java.util.List;

public class QueryFilterVo {
	/**页数*/
	private int pageNo;
	/**每页数量*/
	private int pageSize;
	/**where从句参数*/
	private List<Filter> filterList;
	/**order by 从句参数*/
	private List<Order> orderList;
	
	public QueryFilterVo(int pageNo, int pageSize){
		this.pageNo = pageNo;
		this.pageSize = pageSize;
	}
	
	public QueryFilterVo(int pageNo, int pageSize, List<Filter> filterList, List<Order> orderList){
		this.pageNo = pageNo;
		this.pageSize = pageSize;
		this.filterList = filterList;
		this.orderList = orderList;
	}
	
	
	
	public QueryFilterVo addFilter(Filter filter){
		filterList.add(filter);
		return this;
	}
	
	public QueryFilterVo addFilters(List<Filter> filters){
		filterList.addAll(filters);
		return this;
	}
	
	public QueryFilterVo addOrder(Order order){
		orderList.add(order);
		return this;
	}
	
	public QueryFilterVo addOrders(List<Order> orders){
		orderList.addAll(orders);
		return this;
	}

	public int getPageNo() {
		return pageNo;
	}

	public void setPageNo(int pageNo) {
		this.pageNo = pageNo;
	}

	public int getPageSize() {
		return pageSize;
	}

	public void setPageSize(int pageSize) {
		this.pageSize = pageSize;
	}

	public List<Filter> getFilterList() {
		return filterList;
	}

	public void setFilterList(List<Filter> filterList) {
		this.filterList = filterList;
	}

	public List<Order> getOrderList() {
		return orderList;
	}

	public void setOrderList(List<Order> orderList) {
		this.orderList = orderList;
	}
	
}
